package com.kmproject.haifu.mvp.model.api.service;

import com.kmproject.haifu.mvp.model.entity.ResultBean;
import com.kmproject.haifu.mvp.model.entity.beans.HousePayWayBean;
import com.kmproject.haifu.mvp.model.entity.beans.HouseRentListShowBean;
import com.kmproject.haifu.mvp.model.entity.beans.HouseRentListShowInfoBean;
import com.kmproject.haifu.mvp.model.entity.beans.MyStoreMainBean;
import com.kmproject.haifu.mvp.model.entity.beans.MyStoryBean;
import com.kmproject.haifu.mvp.model.entity.beans.ObtainedHouseBean;
import com.kmproject.haifu.mvp.model.entity.beans.SeletCityBean;

import java.util.List;

import io.reactivex.Observable;
import okhttp3.RequestBody;
import retrofit2.http.Body;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.POST;
import retrofit2.http.Query;
import retrofit2.http.Url;

public interface StoryService {
   //获取已经添加的店铺
    @GET("/app/userStore/listStore/currentUser")
    Observable<ResultBean<List<MyStoryBean>>> listStore(@Query("limit") String limit, @Query("page") String page, @Query("isShow") String isShow, @Query("reviewStatus") String reviewStatus);

    //获取店铺类型
    @FormUrlEncoded
    @POST("/app/dictList")
    Observable<ResultBean<List<HousePayWayBean>>> dictList(@Field("value") String value, @Field("category") String category);

  //添加店铺
   @POST("/app/userStore/addStore")
   Observable<ResultBean<MyStoryBean>> addStore(@Body RequestBody body);

   //开启店铺
    @POST("/app/userStore/enableStore")
    Observable<ResultBean> enableStore(@Body RequestBody body);

   //获取店铺信息根据id
 @GET()
 Observable<ResultBean<MyStoreMainBean>> getStoreInfo(@Url String url);

//更新店铺 "/app/userStore/feign/enableStore"
 @POST()
 Observable<ResultBean<MyStoryBean>> updateStore(@Url String url, @Body RequestBody body);

  //查询下架的租房
 @POST()
 Observable<ResultBean<List<ObtainedHouseBean>>> listHouseRentShelves(@Url String url, @Body RequestBody body);

 //删除房屋
 @FormUrlEncoded
 @POST("/app/removeHouseRent")
 Observable<ResultBean> removeHouse(@Field("rentId") String rentId);

 //删除店铺
 @POST()
 Observable<ResultBean> removeStore(@Url String url, @Body RequestBody body);

 //根据店铺查询租房信息
 @POST("/app/getHouseRentByCurrentStore")
 Observable<ResultBean<List<HouseRentListShowInfoBean>>> listHouseRentByStore(@Body RequestBody body);


}
